import request from '@/utils/request'

export function getList(data, params) {
  return request({
    url: '/sys/role/list',
    method: 'post',
    data,
    params
  })
}

export function saveRole(data) {
  return request({
    url: '/sys/role/save',
    method: 'post',
    data
  })
}

export function saveRoleAuth(data) {
  return request({
    url: '/sys/role/saveRoleAuth',
    method: 'post',
    data
  })
}

export function deleteRole(data) {
  return request({
    url: '/sys/role/delete',
    method: 'post',
    data
  })
}

export function addRoleUser(data) {
  return request({
    url: '/sys/role/addRoleUser',
    method: 'post',
    data
  })
}

export function deleteRoleUserByRole(data) {
  return request({
    url: '/sys/role/deleteRoleUserByRole',
    method: 'post',
    data
  })
}
